<?php
$link=mysql_connect("localhost", "root", "");

if(!$link){
echo "not connected to database";
}

mysql_select_db("techworks");
if (isset($_GET['id'])){
	$id= $_GET['id'];

$q=mysql_query("delete from `tw_cover_page` where `plan_id` = '$id'");

if ($q){
	echo "Plan successfuly deleted";
	header("location: ../incubatee/plan.php");
}else {
	echo mysql_error();
}
}
?>